<template>
  <div>
    <div class="demo-inner-divider">带描述信息</div>
    <div class="row" >
      <e-button @click="open(false)">open</e-button>
      <e-button @click="info(false)">Info</e-button>
      <e-button @click="success(false)">Success</e-button>
      <e-button @click="warning(false)">Warning</e-button>
      <e-button @click="error(false)">Error</e-button>
    </div>
    <div class="demo-inner-divider">仅标题</div>
    <div class="row" >
      <e-button @click="open(true)">open</e-button>
      <e-button @click="info(true)">Info</e-button>
      <e-button @click="success(true)">Success</e-button>
      <e-button @click="warning(true)">Warning</e-button>
      <e-button @click="error(true)">Error</e-button>
    </div>
    <read-me  class="markdown-body"></read-me>
  </div>
</template>
<script>
import ReadMe from '../../docs/notice.md';
export default {
  components: { ReadMe },
  methods: {
    open (nodesc) {
      this.$Notice.open({
        duration: 10000,
        title: 'Notification 标题',
        desc: nodesc ? '' : '这里是Notification的内容，请更换为需要的内容'
      });
    },
    info (nodesc) {
      this.$Notice.info({
        duration: 10000,
        title: 'Notification 标题',
        desc: nodesc ? '' : '这里是Notification的内容，请更换为需要的内容'
      });
    },
    success (nodesc) {
      this.$Notice.success({
        duration: 10000,
        title: 'Notification 标题',
        desc: nodesc ? '' : '这里是Notification的内容，请更换为需要的内容'
      });
    },
    warning (nodesc) {
      this.$Notice.warning({
        duration: 10000,
        title: 'Notification 标题',
        desc: nodesc ? '' : '这里是Notification的内容，请更换为需要的内容'
      });
    },
    error (nodesc) {
      this.$Notice.error({
        duration: 10000,
        title: 'Notification 标题',
        desc: nodesc ? '' : '这里是Notification的内容，请更换为需要的内容'
      });
    }
  }
}
</script>
